package com.bwie.mapper;

import com.bwie.pojo.Goods;
import com.bwie.pojo.Order;
import com.bwie.pojo.ShoppingCart;
import com.bwie.pojo.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ShoppingCartMapper {
    void addShoppingCart(ShoppingCart shoppingCart);

    List<ShoppingCart> shoppingCartList();

    void deleteGoods(Integer id);

    ShoppingCart findCountAndPrice();


    User findUserById(Integer id);

    List<ShoppingCart> findAll();




    void updateInventory(Integer goodsId);

    void delAll(List<Integer> ids);




    void clearShopping(List<ShoppingCart> shoppingCart);


    void buyShopping(@Param("shoppingCart") List<ShoppingCart> shoppingCart, @Param("id") Integer id);


    void addOrder(List<ShoppingCart> shoppingCart);
}
